<div class="contents">
  <form class="form-horizontal" role="form" name="form" ng-submit="save()" novalidate>
  <table style="width: 68%;display: inline-block;" class="table table-striped table-bordered">
    <tbody> 
      <tr><td colspan="4" style="color:blue;font-size: 20px;">订单基本信息</td></tr>
      <tr>
        <td width="140">订单ID</td> <td width="400">{{item.orderId}}</td>
        <td width="140">订单号</td> <td width="400">{{item.oCode}}</td>
       </tr>
      <tr>
        <td>订单金额</td>
        <td>
          <div class="col-sm-5" style="margin: 0;padding: 0" ng-if="item.oStatus == '110'">
            <input type="number" class="form-control" autocomplete="off" ng-model="item.wanAmount" required="required">
            <span class="form-control-feedback">万元</span>
          </div>
          <span ng-if="item.oStatus != '110'">{{item.wanAmount}}万元</span>
        </td>
        <td>前端佣金状态</td> <td class="order-status-{{item.oStatus}}" >{{item.oStatus | orderStatusRender}}</td> 
        
      </tr>
      <tr>
        <td >产品简称</td>
        <td>
          <a ng-click="changeClickNone('#/product/qudaoView?id='+item.oProjectId,'9999'+item.oPType+item.oProjectId,item.oPName)" href="javascript:;">{{item.oPName}}</a>
        </td>
        <td>理财师FAID</td><td >{{item.oFAId}}</td>
      </tr>
      <tr>
         <td>客户姓名</td> <td ><input style="width: 300px;display: inline-block" type="text" class="form-control" ng-if="item.oStatus == '110'" ng-model="item.oCName"> <div class="btn btn-primary ng-scope" ng-click="applySuccess('info')" ng-if="item.oStatus == '110'">修改信息</div><span ng-if="item.oStatus != '110'">{{item.oCName}}</span></td>
         <td>预约时间</td> <td >{{item.createDate | date:'yyyy-MM-dd HH:mm'}}</td>
      </tr>

      <tr ng-if="role!='cwa'&&role!='cwam'"><td colspan="4" style="color:blue;font-size: 20px;">订单价格</td></tr>
      <tr ng-if="role!='cwa'&&role!='cwam'">
        <td colspan="4">
          <table style="border:1px solid #ddd;width: 100%;">
            <tr style="text-align: center;color:#666666;line-height: 33px;"> 
              <th width="180px">金额</th>
              <th width="80px">预期年化率</th>
              <th width="80px">挂网价</th>
              <th width="105px">挂网价(后端)</th>
              <th width="90px">机构价</th>
              <th width="115px">机构价(后端)</th>
            </tr>
            <tr style="line-height: 33px;" ng-repeat="revenue in item.rebateList">
              <td width="90px">{{revenue.annualRevenue.pstartAmount | moneyRender}}-{{revenue.annualRevenue.pendAmount | moneyRender}}</td>
              <td width="80px">{{revenue.annualRevenue.pannualRevenueExpect | profitRender}}</td> 
              <td width="80px">{{revenue.pRabateProfit | profitRender}}</td>
              <td width="105px">{{revenue.pBackRabateProfit | profitRender}}</td>
              <td width="90px">{{revenue.pSellingPrice | profitRender}}</td> 
              <td width="115px">{{revenue.pBackSellingPrice | profitRender}}</td>
            </tr>
          </table>
        </td>
      </tr>

       <tr  ng-repeat="orderCost in item.orderCostList" ng-if="(item.oStatus>=220)">
        <td colspan="4">
          <table class="neworder0815-table" style="line-height: 33px;border:1px solid #ddd;width: 100%;">
            <tr>
              <td colspan="3" style="color:blue;font-size: 20px;">
              {{orderCost.costType | costTypeRender}}</td>
            </tr>
            <tr>
              <td><span ng-if="orderCost.userName">打款姓名：{{orderCost.userName}}</span></td>
              <td><span ng-if="orderCost.bankName">打款银行：{{orderCost.bankName}}</span></td>
            </tr>
            <tr>
               <td ng-if="orderCost.cardNumber">打款账号：{{orderCost.cardNumber}}</td>
               <td ng-if="item.oStatus>'250'">结佣金额：{{orderCost.costAmount}}</td>
            </tr>
             <tr ng-if="!(orderCost.costType | flagCostTypeRender)">
              <td><span ng-if="orderCost.activityFunds>=0">活动打款：{{orderCost.activityFunds}}</span></td>
              <td ng-if="orderCost.activityRemark">活动打款说明：{{orderCost.activityRemark}}</td>
            </tr>
            <tr ng-if="!(orderCost.costType | flagCostTypeRender)">
               <td><span ng-if="orderCost.otherFunds>=0">其他结款：{{orderCost.otherFunds}}</span></td>
              <td><span ng-if="orderCost.otherRemark">其他结款说明：{{orderCost.otherRemark}}</span></td>
            </tr>
            <tr>
               <td><span ng-if="orderCost.remark">备注：{{orderCost.remark}}</span></td>
            </tr>
          </table>
        </td>
      </tr>
      
      <tr ><td>成交价(%)</td> 
          <td ng-if="item.oStatus == '110'"> 
            <input type="number" class="form-control" ng-class="{'new-error-css':form.oTransactionPrice.$invalid}" placeholder="成交价(不带百分号)" name="oTransactionPrice" ng-model="item.oTransactionPrice"  required="required" only-num ng-pattern="/^\d{1,}\.?\d{0,2}$/">
         </td> 
          <td ng-if="item.oStatus != '110'">{{item.oTransactionPrice | profitRender}}</td>
          <td>成交返佣额</td> 
          <td ng-if="item.oStatus == '110'">{{(item.oTransactionPrice * item.oAmount / 100) | moneyRender2:1:1}}</td>
          <td ng-if="item.oStatus != '110'">{{ item.oTransactionRebate | moneyRender2:1:1}}</td>
      </tr>
     <tr>
         <td>订单备注</td> 
         <td colspan="3">  
          {{item.oRemark}}
         </td>
      </tr>
    <tr  ng-repeat="v in backList">
      <td>{{$index>0?'二次':''}}后端成交价</td> <td >{{v.costPrice | profitRender}}</td> 
      <td>{{$index>0?'二次':''}}后端成交返佣额</td> 
      <td >{{v.costAmount | moneyRender2:1:1}}</td> 
    </tr>

     <tr>
       <td ng-if="item.oBackStatus">后端佣金状态</td>
      <td class="order-status-{{item.oBackStatus}}"  ng-if="item.oBackStatus">{{item.oBackStatus | orderStatusRender}}</td> 

        <td ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus == '331'||item.oBackStatus == '361'||!item.oBackStatus)">费用类型</td> 
        <td ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus == '331'||item.oBackStatus == '361'||!item.oBackStatus)">
          <select class="form-control" ng-model="item.costType" ng-options="m.value as m.text for m in dictMap['costTypeModel']"  placeholder="费用类型"><option value="">--选择费用类型--</option></select>
        </td> 
     </tr>


     <tr ng-if="item.oStatus=='140'||item.oStatus=='888'||item.oStatus=='999'">
          <td>订单失败原因</td>
          <td colspan="3">
          {{item.oCancelReason}}
          </td>
      </tr>
  <!--  始终显示 &&showEdit 去除开关 -->
<!--  渠道填写结佣账号-->
     <tr ng-if="(role=='qd'||role=='qdm')&&(item.oStatus == '210'||item.oStatus == '130')">
      <td>打款姓名</td>
      <td>
          <input type="text"  ng-class="{'new-error-css':form.userName.$invalid}" class="form-control" name="userName" placeholder="打款姓名" ng-model="item.userName"  required="required" >
      </td>   
      <td>打款账号</td>
      <td>
          <input type="text" class="form-control" ng-class="{'new-error-css':form.cardNumber.$invalid}" name="cardNumber" placeholder="打款账号" ng-model="item.cardNumber"  required="required" >
      </td>
     </tr>
     <!--  始终显示 &&showEdit 去除开关 -->
     <tr ng-if="(role=='qd'||role=='qdm')&&(item.oStatus == '210'||item.oStatus == '130')">
      <td>打款银行</td>
      <td>
          <input type="text"  ng-class="{'new-error-css':form.bankName.$invalid}" class="form-control" name="bankName" placeholder="打款银行" ng-model="item.bankName"  required="required" >
      </td>   
      <td></td>
       <td></td> 
     </tr>
    
     <tr ng-if="(role=='qd'||role=='qdm')&&(item.oStatus == '210'||item.oStatus == '130')"><td colspan="4" ng-click="clicknum(1)" style="color:blue;font-size: 20px;">结佣账户</td></tr>
     <tr ng-if="(role=='qd'||role=='qdm')&&(item.oStatus == '210'||item.oStatus == '130')">
      <td colspan="4">
          <table style="border:1px solid #ddd;line-height: 33px;">
            <tr style="text-align: center;" ng-click="clicknum(2)"> 
              <th width="100px">选择</th>
              <th width="130px">打款姓名</th>
              <th width="180px">打款银行</th>
              <th width="330px">打款账号</th>
            </tr>
            <tr ng-repeat="bankCard in bankCardList">
              <td width="100px">
                <input type="radio" name="bank" ng-click="setCommissionInformation(bankCard)" />
              </td>
              <td width="130px">{{bankCard.userName}}</td>
              <td width="180px">{{bankCard.bankName}}</td>
              <td width="330px">{{bankCard.cardNumber}}</td>
            </tr>
          </table>
        </td>
     </tr>

<!-- 渠道申请后端结佣 -->
     <tr ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus == '331'||item.oBackStatus == '361'||!item.oBackStatus)">
        
        <td>费用(%)</td>
        <td ><input type="text"  ng-class="{'new-error-css':form.costPrice.$invalid}" class="form-control" name="costPrice" placeholder="费用（百分比数字，不需要输入%）" ng-model="item.costPrice"  required="required" >
        </td> 
        <td>费用金额：</td>
        <td >{{(item.costPrice * item.oAmount / 100) | moneyRender2:1:1}} 
        </td> 
      </tr>

    <tr ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus == '331'||item.oBackStatus == '361'||!item.oBackStatus)">
      <td>打款姓名</td>
      <td>
          <input type="text"  ng-class="{'new-error-css':form.userName.$invalid}" class="form-control" name="userName" placeholder="打款姓名" ng-model="item.userName"  required="required" >
      </td>   
      <td>打款账号</td>
      <td>
          <input type="text" class="form-control" ng-class="{'new-error-css':form.cardNumber.$invalid}" name="cardNumber" placeholder="打款账号" ng-model="item.cardNumber"  required="required" >
      </td>
     </tr>
     <tr ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus == '331'||item.oBackStatus == '361'||!item.oBackStatus)">
      <td>打款银行</td>
      <td>
          <input type="text"  ng-class="{'new-error-css':form.bankName.$invalid}" class="form-control" name="bankName" placeholder="打款银行" ng-model="item.bankName"  required="required" >
      </td>   
      <td>备注</td>
       <td>
         <input type="text"  ng-class="{'new-error-css':form.remark.$invalid}" class="form-control" name="remark" placeholder="备注" ng-model="item.remark"  required="required" >
       </td> 
     </tr>

<!-- 
  产品部 上游结佣 (item.oStatus >= '240' && item.oStatus <= '250')前端
          后端     item.oBackStatus=='261'  
    -->
      <tr ng-if="(role=='cp'||role=='cpm')&&((item.oStatus >= '240' && item.oStatus <= '250')||(item.oBackStatus=='261'&&(m=='03'||m=='07')))&&m!=9">
        <td>打款人</td>
        <td>
            <input type="text"  ng-class="{'new-error-css':form.userName.$invalid}" class="form-control" name="userName" placeholder="打款人" ng-model="item.userName"  required="required" >
        </td>   
        <td>打款账号</td>
        <td>
            <input type="text" class="form-control" ng-class="{'new-error-css':form.cardNumber.$invalid}" name="cardNumber" placeholder="打款账号" ng-model="item.cardNumber"  required="required" >
        </td>
      </tr>
       <tr ng-if="(role=='cp'||role=='cpm')&&((item.oStatus >= '240' && item.oStatus <= '250')||(item.oBackStatus=='261'&&(m=='03'||m=='07')))&&m!=9">
        <td>结佣额(上游/单位：元)</td>
        <td>
            <input type="number" class="form-control" ng-class="{'new-error-css':form.costAmount.$invalid}" name="costAmount" placeholder="结佣额(上游/单位：元)" ng-model="item.costAmount"  required="required" >
        </td>
        <td></td> <td ></td> 
      </tr>

      <tr ng-if="(role=='cp'||role=='cpm')&&((item.oStatus >= '240' && item.oStatus <= '250')||(item.oBackStatus=='261'&&(m=='03'||m=='07')))&&m!=9">
        <td>活动打款(上游/单位：元)</td>
        <td>
            <input type="number" class="form-control" ng-class="{'new-error-css':form.activityFunds.$invalid}" name="activityFunds" placeholder="活动打款(上游/单位：元)" ng-model="item.activityFunds"  required="required" >
        </td>

        <td>活动打款说明(上游)</td>
        <td>
            <input type="text" class="form-control" ng-class="{'new-error-css':form.activityRemark.$invalid}" name="activityRemark" placeholder="活动打款说明(上游)" ng-model="item.activityRemark"  required="required" >
        </td>
      </tr>

      <tr ng-if="(role=='cp'||role=='cpm')&&((item.oStatus >= '240' && item.oStatus <= '250')||(item.oBackStatus=='261'&&(m=='03'||m=='07')))&&m!=9">
        <td>其他结款额(上游/单位：元)</td>
        <td>
            <input type="number" class="form-control" ng-class="{'new-error-css':form.otherFunds.$invalid}" name="otherFunds" placeholder="其他结款额(上游/单位：元)" ng-model="item.otherFunds"  required="required" >
        </td>
        <td>其他结款说明(上游)</td>
        <td>
            <input type="text" class="form-control" ng-class="{'new-error-css':form.otherRemark.$invalid}" name="otherRemark" placeholder="其他结款说明(上游)" ng-model="item.otherRemark"  required="required" >
        </td>
      </tr>

<!-- 财务结佣 前结佣-->
       <tr ng-if="(role=='cwa'||role=='cwam')&&item.oStatus == '310' && item.shiZhuFlag != '0'">
        <td >财务结佣(单位：元)</td> 
        <td>
        <input type="number" class="form-control" placeholder="财务结佣(单位：元)" ng-class="{'new-error-css':form.costAmount.$invalid}" name="costAmount" ng-model="item.costAmount" required="required" only-num ng-pattern="/^\d{1,}\.?\d{0,2}$/"></td> 
        <td></td>
        <td ></td> 
      </tr>
      <tr ng-if="(role=='cwa'||role=='cwam')&&item.oStatus == '310' && item.shiZhuFlag != '0'">
        <td>活动打款(财务/单位：元)</td> 
        <td>
           <input type="number" class="form-control" ng-class="{'new-error-css':form.activityFunds.$invalid}" name="activityFunds" placeholder="活动打款(财务/单位：元)"  ng-model="item.activityFunds" required="required" only-num ng-pattern="/^\d{1,}\.?\d{0,2}$/">
        </td> 
        <td>活动打款说明(财务)</td>
         <td>
          <input type="text" class="form-control" ng-class="{'new-error-css':form.activityRemark.$invalid}" name="activityRemark" placeholder="活动打款说明(财务)" ng-model="item.activityRemark"  required="required" ></td> 
      </tr>
      <tr ng-if="(role=='cwa'||role=='cwam')&&item.oStatus == '310' && item.shiZhuFlag != '0'">
        <td>其他打款额(财务/单位：元)</td> 
        <td>
           <input type="number" class="form-control" ng-class="{'new-error-css':form.otherFunds.$invalid}" name="otherFunds" placeholder="其他打款额(财务/单位：元)"  ng-model="item.otherFunds" required="required" only-num ng-pattern="/^\d{1,}\.?\d{0,2}$/">
        </td> 
        <td>其他打款说明(财务)</td>
         <td>
          <input type="text" class="form-control" ng-class="{'new-error-css':form.otherRemark.$invalid}" name="otherRemark" placeholder="其他打款说明(财务)" ng-model="item.otherRemark"  required="required" ></td>
      </tr>

      <!-- 财务结佣  后端结佣金额  -->
 
      <tr ng-if="(role=='cwa'||role=='cwam')&&item.oStatus != '310'&&(item.oBackStatus == '311')&&(m=='03'||m=='07')">
        <td>结佣金额(财务/单位：元)</td> 
        <td>
           <input type="number" class="form-control" ng-class="{'new-error-css':form.costAmount .$invalid}" name="costAmount " placeholder="结佣金额(财务/单位：元)"  ng-model="item.costAmount " required="required" only-num ng-pattern="/^\d{1,}\.?\d{0,2}$/">
        </td> 
      </tr>

     

      <tr>
        <td>相关操作</td>
        <td colspan="3">
          <div  class="btn btn-primary" disabled="disabled" ng-if="item.oStatus == '320'">等待返佣确认</div>
          <div  class="btn btn-primary" disabled="disabled" ng-if="item.oStatus == '210'">等待打款</div>
          <div  class="btn btn-primary" ng-click="applySuccess()" ng-if="item.oStatus == '110'">预约成功</div>

          <div  class="btn btn-primary "  ng-click="showVisitLayer2()" ng-if="item.oStatus == '110'">预约失败</div>

          <div  class="btn btn-red "   ng-click="showVisitLayer()" ng-if="m!=9&&item.oStatus>=130&&item.oStatus < '220' && item.oStatus != '140'&& item.oStatus != '120'">订单失败</div>

          <div class="btn btn-primary" disabled="disabled" ng-if="!(role=='cp'||role=='cpm')&&item.oStatus == '220'">确认到款</div>
         
          <div  class="btn btn-primary" disabled="disabled" ng-if="item.oStatus == '310'&&!(role=='cwa'||role=='cwam')&&(m=='01'||m=='05')">财务结佣</div>

          <div  class="btn btn-primary" disabled='disabled' ng-if="item.oCancelReason == '审核未通过'" >{{item.oCancelReason}}</div>


          <div class="btn btn-primary" disabled="disabled" ng-if="m!=03&&m!=07&&item.oStatus >= '240' && item.oStatus <= '250'&&!(role=='cp'||role=='cpm')&&(m=='01'||m=='05')">待佣金到账</div>

          <div  class="btn btn-primary" ng-click="frontRabite('quanduan')" ng-if="item.oStatus >= '240' && item.oStatus <= '250'&&(role=='cp'||role=='cpm')&&(m=='01'||m=='05')">佣金到账</div>

          <div  class="btn btn-primary" ng-click="frontRabite('houduan')" ng-if="item.oBackStatus =='261' &&(role=='cp'||role=='cpm')&&m!=9&&(m=='03'||m=='07')">后端佣金到账</div>

          <!-- 渠道 确认打款  返佣  -->
          <div  class="btn btn-warning" ng-click="process()" ng-if="(role=='qd'||role=='qdm')&&(item.oStatus == '210'||item.oStatus == '130')">已签约打款</div>
          <div  class="btn btn-warning" ng-click="comfirmFrontRabite()" ng-if="item.oStatus == '320'&&(role=='qd'||role=='qdm')&&(m=='01'||m=='05')">确认返佣</div>

           <div  class="btn btn-warning" ng-click="comfirmBackRabite()" ng-if="item.oBackStatus == '321'&&(role=='qd'||role=='qdm')&&(m=='03'||m=='07')">确认返佣(后)</div>
          
          <div  class="btn btn-primary" ng-if="!((role=='cp'||role=='cpm')&&m=='09')&&item.oStatus == '120'" disabled="disabled">审核中...</div>
          <div  class="btn btn-primary" ng-if="!(role=='cp'||role=='cpm')&&item.oBackStatus == '241'" disabled="disabled">后端结佣审核中...</div>
          <!-- 产品审核 确认到款 后端返佣-->
          <div  class="btn btn-primary" ng-click="comfirmPay()" ng-if="(role=='cp'||role=='cpm')&&item.oStatus == '220'&&(m=='01'||m=='05')">确认到款</div>
          <span class="col-sm-3"  ng-if="(role=='cp'||role=='cpm')&&item.oStatus == '220'&&(m=='01'||m=='05')">
            <input type="radio" value='true' ng-model="item.flagBaoxiao">包销 
            &nbsp;
            <input type="radio" value='false' ng-model="item.flagBaoxiao">分销
          </span>
          <div  ng-if="(role=='cp'||role=='cpm')&&m=='09'&&item.oStatus == '120'" ng-click="isInvestigate(item.orderId,'yes')" class="btn btn-primary" >审核通过</div>
          <div ng-if="(role=='cp'||role=='cpm')&&m=='09'&& item.oStatus == '120'" ng-click="isInvestigate(item.orderId,'no')" class="btn btn-primary" >审核失败</div>
          <div  ng-if="(role=='cp'||role=='cpm')&&m=='09'&&item.oBackStatus == '241'" ng-click="checkBackFront('yes')" class="btn btn-primary" >后端返佣审核通过</div>
          <div ng-if="(role=='cp'||role=='cpm')&&m=='09'&& item.oBackStatus == '241'" ng-click="checkBackFront('no')" class="btn btn-primary" >后端返佣审核失败</div>
          <div  class="btn btn-primary" ng-click="closeTrade()" ng-if="item.oStatus >= '330'&&item.oStatus <= '350'&&(role=='cp'||role=='cpm')&&(m=='01'||m=='05')">结束交易</div>
         <div  class="btn btn-primary" disabled="disabled" ng-if="item.oStatus == '360'&&(m!=09)">交易结束</div>
         <!-- 渠道申请后端结佣-->
         <div  class="btn btn-primary" ng-click="applyBackFront()" ng-if="hdjy=='true'&&item.backApplyStatus&&(role=='qd'||role=='qdm')&&(item.oStatus == '330'||item.oStatus == '360')&&(item.oBackStatus=='361'||item.oBackStatus=='331'||!item.oBackStatus)&&(m=='01'||m=='05')">申请后端结佣</div>
         <!-- 财务后台结佣 -->
          <div  class="btn btn-primary" ng-click="backFinance()" ng-if="(role=='cwa'||role=='cwam')&&(item.oBackStatus == '311')&&(m=='03'||m=='07')">后端结佣</div>
          <!-- 前端确认结佣-->
          <div  class="btn btn-primary" ng-click="frontFinance(2)" ng-if="item.oStatus == '310' && item.shiZhuFlag != '0'&&(role=='cwa'||role=='cwam')&&(m=='01'||m=='05')">确认结佣</div>
        </td>
    </tr>
    </tbody>
  </table> 
  <div style="border:1px solid #ddd;padding-left:50px;width:30%;float:right;">
    <ul >
      <li style="margin-top:10px;font-size: 20px;color:blue">订单追踪</li>
      <li style="margin-top:20px;list-style-type: disc;" ng-repeat="it in item.orderFlowList">
       {{it.oBackStatus?"后端：":""}}{{it.oStatus||it.oBackStatus|orderStatusRender}} &nbsp;&nbsp; 操作人：{{it.createBy | createByFilterByRender}}<br/>
       {{it.flowDate | date:'yyyy-MM-dd HH:mm'}}
      </li>
    </ul>
  </div>
  
  </form>
<div class="layer-box" ng-show="isShowVisitLayer">
  <div class="layer-bg"></div>
  <div class="layer-con " style="padding:10px 20px; width:450px; left:40%">
    <span class="icons-close" title="关闭" ng-click="isShowVisitLayer = false;">X</span>
    <div class="layer-title">
      FAID:{{item.oFAId}}
    </div>
    <div class="con-wrap">
      <div class="form-group" >
     <form class="form-horizontal" role="form" name="itll" ng-submit="save()" >
        <table class="table table-striped table-bordered">
          <tr>
            <td width="120px">操作人</td>
            <td width="120px">操作时间</td>
            <td width="190px">失败原因</td>
          </tr>

          <tr ng-if="item.oStatus=='888'">
            <td>{{item.updateBy}}</td>
            <td>{{item.updateDate}}</td>
            <td>{{item.oCancelReason}}</td>
          </tr>
        </table>


        <table class="table table-striped table-bordered">
          
          <tr>
            <td><input type="text" ng-class="{'new-error-css':itll.oCancelReason.$invalid}" name="oCancelReason" class="form-control" placeholder="订单失败原因"  ng-model="item.oCancelReason" required="required" /></td>
            <td>
              <input type="button" value="确认失败"  class="btn btn-small btn-warning" ng-click="confirmFailure()"  />
            </td>
          </tr>
        </table>
      </form>
      </div>
    </div>
  </div>
</div> 

<div class="layer-box" ng-show="isShowVisitLayer2">
  <div class="layer-bg"></div>
  <div class="layer-con " style="padding:10px 20px; width:450px; left:40%">
    <span class="icons-close" title="关闭" ng-click="isShowVisitLayer2 = false;">X</span>
    <div class="layer-title">
      FAID:{{item.oFAId}}
    </div>
    <div class="con-wrap">
      <div class="form-group" >
     <form class="form-horizontal" role="form" name="itll" ng-submit="save()" >
        <table class="table table-striped table-bordered">
          <tr>
            <td width="120px">操作人</td>
            <td width="120px">操作时间</td>
            <td width="190px">失败原因</td>
          </tr>

          <tr ng-if="item.oStatus=='888'">
            <td>{{item.updateBy}}</td>
            <td>{{item.updateDate}}</td>
            <td>{{item.oCancelReason}}</td>
          </tr>
        </table>


        <table class="table table-striped table-bordered">
          
          <tr>
            <td>
            <!--
              <input type="text" ng-class="{'new-error-css':itll.oCancelReason.$invalid}" name="oCancelReason" class="form-control" placeholder="预约失败原因"  ng-model="item.oCancelReason" required="required" />
              -->
              <select  class="form-control" placeholder="预约失败原因" ng-model="item.oCancelReason" required="required">
                <option value="">--请选择预约失败原因--</option>
                <option value="客户未打款">客户未打款</option>
                <option value="订单操作错误">订单操作错误</option>
                <option value="流程测试">流程测试</option>
                <option value="其他">其他</option>
              </select>     
            </td>
            <td>
              <input type="button" value="确认失败"  class="btn btn-small btn-warning" ng-click="applyFail()"  />
            </td>
          </tr>
        </table>
      </form>
      </div>
    </div>
  </div>
</div> 

</div>


